#include <iostream>
using namespace std;

class Car;
class Driver {
public:
	void modifyCar(Car* car);
};

class Car {
private:
	int price;
	friend int mostExpensiveCar(Car cars[], int n);
	friend void Driver::modifyCar(Car* car);
};

void Driver::modifyCar(Car* car) {
	car->price += 1000;
}

int mostExpensiveCar(Car cars[], int n) {
	int tmpmax = -1;
	for (int i = 0; i < n; ++i)
		if (tmpmax < cars[i].price)
			tmpmax = cars[i].price;
	return tmpmax;
}

int main()
{
	return 0;
}